package cn.campus.enums.article;

/**
 * @Description: 结果枚举类
 * @Author: linyanbin
 * @Date: 2018/9/17 0017 9:45
 */
public enum ResultEnum {

    USER_NOT_LOGIN(95, "用户未登陆!"),
    READ_FILE_ERROR(96, "读取文件错误!"),
    USER_NOT_EXIST(97,"用户不存在!"),
    ARTICLE_NOT_EXIST(98, "文章不存在!"),
    ADD_ARTICLE_FAIL(99, "添加文章失败!"),
    UPDATE_ARTICLE_FAIL(100, "更新文章失败!"),
    REMOVE_ARTICLE_FAIL(101, "删除文章失败!"),
    ARTICLE_IMG_ERROR(102, "文章图片错误!"),
    REQUEST_TYPE_ERROR(103, "请求类型错误!"),
    COMMENT_NOT_EXIST(104, "评论不存在!"),
    UPDATE_COMMENT_FAIL(105, "更新评论失败!"),
    ADD_COMMENT_FAIL(106, "添加评论失败!"),
    REMOVE_COMMENT_FAIL(107, "删除评论失败!"),

    ;
    ;

    /** 自定义状态码 **/
    private Integer code;

    /** 提示信息 **/
    private String msg;

    ResultEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

}
